//
//  LGSchedulFooterView.m
//  HeartDiseaseManage
//
//  Created by 1234 on 2023/6/12.
//

#import "LGSchedulFooterView.h"

@interface LGSchedulFooterView()
/**   */
@property (nonatomic , strong)UIView *baseView;
@end

@implementation LGSchedulFooterView

- (instancetype)initWithFrame:(CGRect)frame{
    self = [super initWithFrame:frame];
    if (self) {
        self.clipsToBounds = YES;
        self.backgroundColor = [UIColor colorWithString:@"#F9F9F9"];
        [self addSubview:self.baseView];
        [self addSubview:self.addButton];
    }
    return self;
}

-(UIView *)baseView{
    if(!_baseView){
        _baseView = [UIView shadowViewWithColor:@"#B3C5D9" offset:CGSizeMake(0, 2) opacity:0.15 radius:15];
        _baseView.frame = CGRectMake(viewPix(16), -viewPix(10), Screen_W-viewPix(32), viewPix(55));
        _baseView.backgroundColor = [UIColor whiteColor];
    }
    return _baseView;
}

-(UIButton *)addButton{
    if(!_addButton){
        _addButton = [UIButton buttonWithTitle:@"添加排班" titleFont:LGFontWeight(15, UIFontWeightMedium) textColor:@"#3291FF" imageName:@""];
        _addButton.frame = CGRectMake(viewPix(28), viewPix(5), Screen_W-viewPix(56), viewPix(30));
        _addButton.layer.borderColor = [UIColor colorWithString:@"#3291FF"].CGColor;
        _addButton.layer.borderWidth = 0.5;
        _addButton.cornerRidus = viewPix(15);
    }
    return _addButton;
}

@end
